package org.example.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class HelloController {

    @GetMapping("/")  //根目录返回html页面
    public String hello() {
        return "五子棋.html";
    }

    @RequestMapping("/home")
    public String home() {
        return "redirect:/"; // 跳转到根目录
    }
}


